<?php
/**
 * Created by PhpStorm.
 * User: chenishr
 * Date: 2018/7/12
 * Time: 10:45 PM
 */
namespace Hanson\MyVbot;
require __DIR__.'/vendor/autoload.php';

/*
use Hanson\MyVbot\Amazon\Comment\Comments;

$res = Comments::get_comments('',131);

print_r($res);
 */


use Hanson\MyVbot\Html\Pdfcrowd;
$res = Pdfcrowd::html_to_pdf("https://mp.weixin.qq.com/s/Rewk2wdqkxCQM0qFln3tEg");
var_dump($res);

//file_put_contents("tmp/wx.html",file_get_contents("http://mp.weixin.qq.com/s?__biz=MzIxMjE5MTE1Nw==&amp;mid=2653194666&amp;idx=1&amp;sn=69ce32870c0b981c40b1e124fbb6bba8&amp;chksm=8c99fb70bbee72668cad223892ad362525d215e7f936458f99dd289eb82981099359310e9e54&amp;mpshare=1&amp;scene=1&amp;srcid=07218JtvEHJVNWzbFh7UpeCC#rd"));
//$conents = file_get_contents("http://mp.weixin.qq.com/s?__biz=MzIxMjE5MTE1Nw==&amp;mid=2653194666&amp;idx=1&amp;sn=69ce32870c0b981c40b1e124fbb6bba8&amp;chksm=8c99fb70bbee72668cad223892ad362525d215e7f936458f99dd289eb82981099359310e9e54&amp;mpshare=1&amp;scene=1&amp;srcid=07218JtvEHJVNWzbFh7UpeCC#rd");
//$conents = str_replace('data-src','src',$conents);
//$conents = str_replace('<head>','<head> <meta name="referrer" content="never"> ',$conents);
//file_put_contents('tmp/wx-re.html',$conents);

//use Qiniu\Storage\UploadManager;
//use Qiniu\Auth;
//$upManager = new UploadManager();
//$auth = new Auth('XJC98xJkC0GO5ye-bk2WYRGw21kzT-2wN0rB5gGB', '5CpEKTVwzehFzWC4K7TwUGnwg8nrfyTC2kEoWqYR');
//$token = $auth->uploadToken('chenishr');
//$conents = str_replace('data-src','src',$conents);
//$conents = str_replace('<head>','<head> <meta name="referrer" content="never"> ',$conents);
//list($ret, $error) = $upManager->put($token, 'wechat-article/test3.html', $conents);
//$bucketUrl = "http://7xl42u.com1.z0.glb.clouddn.com/";
//var_dump($ret);
//var_dump($error);
